package com.epfresh.bean;

import java.util.List;

/**
 * Created by wzh on 16-7-6.
 */
public class BookHome {


    /**
     * unPayPrice : 2454.59
     * payedPrice : 0.01
     * queryTotleIncome : 2454.6
     * topCategoryList : [{"name":null,"categoryId":2,"categoryName":"水果","queryDate":"2017-05","categoryIds":"2","price":1064.57,"ratio":0.43},{"name":null,"categoryId":3,"categoryName":"肉类","queryDate":"2017-05","categoryIds":"3","price":994.01,"ratio":0.41},{"name":null,"categoryId":1,"categoryName":"蔬菜","queryDate":"2017-05","categoryIds":"1","price":201.82,"ratio":0.08},{"name":null,"categoryId":4,"categoryName":"禽蛋","queryDate":"2017-05","categoryIds":"4","price":194.2,"ratio":0.08}]
     * queryDateList : [{"name":"2017年","queryDate":"2017","child":[{"name":"2017年05月","queryDate":"2017-05","child":[]},{"name":"2017年04月","queryDate":"2017-04","child":[]},{"name":"2017年03月","queryDate":"2017-03","child":[]},{"name":"2017年02月","queryDate":"2017-02","child":[]},{"name":"2017年01月","queryDate":"2017-01","child":[]}]}]
     * trendList : [{"name":"01日","queryDate":"2017-05-01","productId":null,"price":0,"type":1},{"name":"02日","queryDate":"2017-05-02","productId":null,"price":194.2,"type":1},{"name":"03日","queryDate":"2017-05-03","productId":null,"price":994,"type":1},{"name":"04日","queryDate":"2017-05-04","productId":null,"price":1266.4,"type":1},{"name":"05日","queryDate":"2017-05-05","productId":null,"price":0,"type":1},{"name":"06日","queryDate":"2017-05-06","productId":null,"price":0,"type":1},{"name":"07日","queryDate":"2017-05-07","productId":null,"price":0,"type":1},{"name":"08日","queryDate":"2017-05-08","productId":null,"price":0,"type":1}]
     * detailList : [{"name":"05-08","queryDate":"2017-05-08","productId":null,"price":0,"type":1},{"name":"05-07","queryDate":"2017-05-07","productId":null,"price":0,"type":1},{"name":"05-06","queryDate":"2017-05-06","productId":null,"price":0,"type":1},{"name":"05-05","queryDate":"2017-05-05","productId":null,"price":0,"type":1},{"name":"05-04","queryDate":"2017-05-04","productId":null,"price":1266.4,"type":1},{"name":"05-03","queryDate":"2017-05-03","productId":null,"price":994,"type":1},{"name":"05-02","queryDate":"2017-05-02","productId":null,"price":194.2,"type":1},{"name":"05-01","queryDate":"2017-05-01","productId":null,"price":0,"type":1}]
     * queryDate : 2017-05
     * trendMax : 1266.4
     */

    private String queryDateTitle;

    public String getQueryDateTitle() {
        return queryDateTitle;
    }

    public void setQueryDateTitle(String queryDateTitle) {
        this.queryDateTitle = queryDateTitle;
    }

    private String unPayPrice;
    private String payedPrice;
    private String queryTotleIncome;
    private String queryDate;
    private String trendMax;
    private List<TopCategoryListBean> topCategoryList;
    private List<QueryDateListBean> queryDateList;
    private List<TrendListBean> trendList;
    private List<DetailListBean> detailList;

    public String getUnPayPrice() {
        return unPayPrice;
    }

    public void setUnPayPrice(String unPayPrice) {
        this.unPayPrice = unPayPrice;
    }

    public String getPayedPrice() {
        return payedPrice;
    }

    public void setPayedPrice(String payedPrice) {
        this.payedPrice = payedPrice;
    }

    public String getQueryTotleIncome() {
        return queryTotleIncome;
    }

    public void setQueryTotleIncome(String queryTotleIncome) {
        this.queryTotleIncome = queryTotleIncome;
    }

    public String getQueryDate() {
        return queryDate;
    }

    public void setQueryDate(String queryDate) {
        this.queryDate = queryDate;
    }

    public String getTrendMax() {
        return trendMax;
    }

    public void setTrendMax(String trendMax) {
        this.trendMax = trendMax;
    }

    public List<TopCategoryListBean> getTopCategoryList() {
        return topCategoryList;
    }

    public void setTopCategoryList(List<TopCategoryListBean> topCategoryList) {
        this.topCategoryList = topCategoryList;
    }

    public List<QueryDateListBean> getQueryDateList() {
        return queryDateList;
    }

    public void setQueryDateList(List<QueryDateListBean> queryDateList) {
        this.queryDateList = queryDateList;
    }

    public List<TrendListBean> getTrendList() {
        return trendList;
    }

    public void setTrendList(List<TrendListBean> trendList) {
        this.trendList = trendList;
    }

    public List<DetailListBean> getDetailList() {
        return detailList;
    }

    public void setDetailList(List<DetailListBean> detailList) {
        this.detailList = detailList;
    }

    public static class TopCategoryListBean {
        /**
         * name : null
         * categoryId : 2
         * categoryName : 水果
         * queryDate : 2017-05
         * categoryIds : 2
         * price : 1064.57
         * ratio : 0.43
         */

        private String name;
        private String categoryId;
        private String categoryName;
        private String queryDate;
        private String categoryIds;
        private String price;
        private String ratio;

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public String getCategoryId() {
            return categoryId;
        }

        public void setCategoryId(String categoryId) {
            this.categoryId = categoryId;
        }

        public String getCategoryName() {
            return categoryName;
        }

        public void setCategoryName(String categoryName) {
            this.categoryName = categoryName;
        }

        public String getQueryDate() {
            return queryDate;
        }

        public void setQueryDate(String queryDate) {
            this.queryDate = queryDate;
        }

        public String getCategoryIds() {
            return categoryIds;
        }

        public void setCategoryIds(String categoryIds) {
            this.categoryIds = categoryIds;
        }

        public String getPrice() {
            return price;
        }

        public void setPrice(String price) {
            this.price = price;
        }

        public String getRatio() {
            return ratio;
        }

        public void setRatio(String ratio) {
            this.ratio = ratio;
        }
    }

    public static class QueryDateListBean {
        /**
         * name : 2017年
         * queryDate : 2017
         * child : [{"name":"2017年05月","queryDate":"2017-05","child":[]},{"name":"2017年04月","queryDate":"2017-04","child":[]},{"name":"2017年03月","queryDate":"2017-03","child":[]},{"name":"2017年02月","queryDate":"2017-02","child":[]},{"name":"2017年01月","queryDate":"2017-01","child":[]}]
         */

        private String name;
        private String queryDate;
        private List<QueryDateListBean> child;

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public String getQueryDate() {
            return queryDate;
        }

        public void setQueryDate(String queryDate) {
            this.queryDate = queryDate;
        }

        public List<QueryDateListBean> getChild() {
            return child;
        }

        public void setChild(List<QueryDateListBean> child) {
            this.child = child;
        }

    }

    public static class TrendListBean {
        /**
         * name : 01日
         * queryDate : 2017-05-01
         * productId : null
         * price : 0.0
         * type : 1
         */

        private String name;
        private String queryDate;
        private String productId;
        private String price;
        private String type;

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public String getQueryDate() {
            return queryDate;
        }

        public void setQueryDate(String queryDate) {
            this.queryDate = queryDate;
        }

        public String getProductId() {
            return productId;
        }

        public void setProductId(String productId) {
            this.productId = productId;
        }

        public String getPrice() {
            return price;
        }
        public Double getPriceY() {
            try {
                if (price != null && !"".equals(price)){
                    return Double.valueOf(price);
                }
            }catch (Exception e){
                e.printStackTrace();
            }

            return 0d;
        }
        public void setPrice(String price) {
            this.price = price;
        }

        public String getType() {
            return type;
        }

        public void setType(String type) {
            this.type = type;
        }
    }

    public static class DetailListBean {
        /**
         * name : 05-08
         * queryDate : 2017-05-08
         * productId : null
         * price : 0.0
         * type : 1
         */

        private String name;
        private String queryDate;
        private String productId;
        private String price;
        private String type;

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public String getQueryDate() {
            return queryDate;
        }

        public void setQueryDate(String queryDate) {
            this.queryDate = queryDate;
        }

        public String getProductId() {
            return productId;
        }

        public void setProductId(String productId) {
            this.productId = productId;
        }

        public String getPrice() {
            return price;
        }

        public void setPrice(String price) {
            this.price = price;
        }

        public String getType() {
            return type;
        }

        public void setType(String type) {
            this.type = type;
        }
    }
}
